aosp06 您所在的位置:网站首页 mac 编译 lineageos aosp06

aosp06

2024-07-15 23:39| 来源: 网络整理| 查看: 265

文章目录  [隐藏] 1.Ubuntu设置1.1.配置USB调试手机1.2.设置编译器缓存1.3.须要的jdk版本2.下载lineageos源码2.1.查找支持的手机2.2.下载源码3.准备MiNote3手机硬件文件3.1.挂载lineageos镜像3.2.拉取设备特定代码文件3.3.验证设备特定代码文件4.编译

Ubuntu20 小米Note3(已刷lineageos,http://www.gaohaiyan.com/3728.html)

1.Ubuntu设置 1.1.配置USB调试手机

查看手机的ID: $lsusb Bus 003 Device 003: ID 18d1:4ee7 Google Inc. Mi Note 3 使用root用户创建 /etc/udev/rules.d/70-android.rules 文件,并输入 SUBSYSTEM=="usb", ATTRS{idVendor}=="18d1", ATTRS{idProduct}=="4ee7", MODE="0666" $ sudo chmod a+r 70-android.rules $ sudo service udev restart 把手机重新插到电脑上,提示“允许USB调试吗?这台计算机的RSA密钥xxxx,一律允许xxx”时,允许。 $ adb devices

1.2.设置编译器缓存

$ sudo apt install ccache -y 然后设置大小 export USE_CCACHE=1 ccache -M 50G export CCACHE_COMPRESS=1 可以把export加到 .bashrc 文件中。

1.3.须要的jdk版本

https://wiki.lineageos.org/devices/jason/build#java

2.下载lineageos源码 2.1.查找支持的手机

查看支持的设备 https://wiki.lineageos.org/devices/ 根据手机代号查看支持的版本 https://wiki.lineageos.org/devices/jason/build#initialize-the-lineageos-source-repository

2.2.下载源码

第1步,配置git的姓名和电子邮件地址,如果不提交代码,按下默认即可。 $ git config --global user.email "[email protected]" $ git config --global user.name "Your Name" 第2步,在 ~/.bashrc 中加入命令 export REPO_URL=’https://mirrors.tuna.tsinghua.edu.cn/git/git-repo/’ 刷新 $ source ~/.bashrc 第3步,初始化 镜像站 https://mirrors.tuna.tsinghua.edu.cn/help/lineageOS/ 创建工作目录并拉取配置: $ mkdir lineage18.1 下文用 %lineage% 表示这个路径。 $ cd lineage18.1 $ repo init -u https://mirrors.tuna.tsinghua.edu.cn/git/lineageOS/LineageOS/android.git -b lineage-18.1 如果出现

Downloading Repo source from https://mirrors.tuna.tsinghua.edu.cn/git/git-repo/ fatal: 无法访问 'https://mirrors.tuna.tsinghua.edu.cn/git/git-repo/':server certificate verification failed. CAfile: none CRLfile: none repo: error: "git" failed with exit status 128 cwd: /home/happy/aosp/lineage18.1/.repo/repo cmd: ['git', 'fetch', '--quiet', '--progress', 'origin', '+refs/heads/*:refs/remotes/origin/*', '+refs/tags/*:refs/tags/*'] fatal: double check your --repo-rev setting. fatal: cloning the git-repo repository failed, will remove '.repo/repo'.

把REPO_URL、‘repo init -u’的协议换为http。 第4步,打开.repo/manifests/default.xml, ● 将   改成     ● 将  



【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

    专题文章
      CopyRight 2018-2019 实验室设备网 版权所有